home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / telecomm / storm100.lzh / LISTBOX.BAS < prev    next >
BASIC Source File  |  1993-11-03  |  1KB  |  58 lines

  1. 'Demonstration of listbox of names
  2. 'when selected, sends name and PPN
  3. 'useful if you can't remember a PPN
  4. 'Hope I got all the PPN's right!!!
  5. FAST ON
  6. DIM p$(100),ppn$(100)
  7. flag = 1
  8. x = 1
  9. WHILE flag
  10.     READ p$(x),ppn$(x)
  11. IF p$(x) = "" THEN
  12.         flag = 0
  13. ELSE
  14.         x = x + 1
  15. ENDIF
  16. WEND
  17. x = x - 1
  18. t$ = "Pick Name"
  19. 'To see auto-search, press the first letter of a name'
  20. result = LISTBOX(t$,p$(1),x)
  21. IF result = 0 THEN END
  22. name$ = p$(result)
  23. comma = INSTR(name$,",")
  24.     IF comma = 0 THEN
  25.         SEND name$;
  26.     ELSE
  27.         SEND MID$(name$,comma + 1);
  28.         SEND LEFT$(name$,comma - 1);
  29. FAST OFF
  30. FAST OFF
  31.     ENDIF
  32. SEND " ";ppn$(result)
  33. END
  34. FAST OFF
  35. FAST OFF
  36. DATA " Amsler,John J.","70275,676"
  37. DATA " Atari Explorer","70007,3615"
  38. DATA " Augustine,Pat","73670,2200"
  39. DATA " Aycock,Bill","76703,4061"
  40. DATA " Davis,John","76711,127"
  41. DATA " Dougherty,Hal","70007,4510"
  42. DATA " Fulton,Mike","75300,1141"
  43. DATA " Joins,Keith","76702,375"
  44. DATA " Lebow,Don","76704,41"
  45. DATA " Luks,Ron","76703,254"
  46. DATA " Molodyi,Boris","70322,624"
  47. DATA " Ness,Jim","75300,3155"
  48. DATA " Page,Alan","72227,3507"
  49. DATA " Puff,Bob","76702,1076"
  50. DATA " Ramsden,David","76703,4224"
  51. DATA " Retelle,Bob","76702,1466"
  52. DATA " Rhea,Dan","76703,4364"
  53. DATA " Schoenbach,Mike","76703,4363"
  54. DATA " STReport","70007,4454"
  55. DATA " Wageman,Greg","74016,352"
  56. DATA "",""
  57.  
  58.